#!/bin/bash

SSH_OPTS='-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no'


while test -n "$1" ; do
	case $1 in
		-host)
			shift
			HOST=$1
			shift
			;;
		-key)
			shift
			KEY=$1
			shift
			;;
	esac
done


ssh $SSH_OPTS -i $KEY ubuntu@$HOST "killall -s SIGKILL java"


